package com.fms.gui.existingSheets.buttons;

import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import javax.swing.JButton;

import com.fms.model.domain.FlowSheet;
import com.fms.model.editor.IFlowSheetEditor;

class EmailButton extends JButton implements ActionListener
{
	/**
	 * 
	 */
	private static final long	serialVersionUID	= -4383514540843720716L;
	private FlowSheet sheet;
	private IFlowSheetEditor editor;
	
	
	public EmailButton(IFlowSheetEditor _editor, FlowSheet sheet)
	{
		this.setText("Open");
		this.editor = _editor;
		this.sheet = sheet;
		this.addActionListener(this);
	}

	@Override
	public void actionPerformed(ActionEvent arg0)
	{
		this.editor.edit(sheet);
	}
	
}